import { ResultEnum } from '../../enums/httpEnum'

const listReposDetails = {
  count: '10',
  'list|10': [
    {
      category: '@name',
      createdAt: '@date("yyyy-MM-dd")',
      description: '',
      name: '@name',
      namespace: '@name',
      numDownload: 5,
      numImages: 6,
      path: '@name',
      size: 15151,
      totalRange: 5,
      updatedAt: '@date("yyyy-MM-dd")'
    }
  ],
  offset: '1',
  total: '50'
}

const listNamespaces = {
  'list|3': [
    {
      id: '@id',
      name: '@name'
    }
  ]
}
const listRepositoryTags = {
  count: '10',
  'list|10': [
    {
      created: '@date("yyyy-MM-dd")',
      id: '@id',
      imageId: 'ss',
      internalPath: 'ss',
      path: 'ss',
      repoId: 0,
      schema: '',
      size: 15151,
      tag: '12',
      tagType: 1,
      updated: '@date("yyyy-MM-dd")'
    }
  ],
  offset: '1',
  total: '50'
}

const listNamespaced = {
  'list|10': [
    {
      labels: {
        asfddsadsad: 'asdqwe2132',
        asdqwe21321: 'asdqwe2133'
      },
      name: '@name',
      'phase|1': ['Active', 'Terminating'],
      time: '@date("yyyy-MM-dd")',
      'type|1': [0, 1]
    }
  ]
}
const namespacedYaml = {
  jsonStr:
    '{"apiVersion":"v1","kind":"Namespace","metadata":{"annotations":{"optimized-by-cce":"true"},"creationTimestamp":1666691675000,"labels":{"kubernetes.io/metadata.name":"biao-pu-cloud-2022","project":"biao-pu-cloud-2022"},"managedFields":[{"apiVersion":"v1","fieldsType":"FieldsV1","fieldsV1":{"f:metadata":{"f:annotations":{".":{},"f:optimized-by-cce":{}},"f:labels":{".":{},"f:kubernetes.io/metadata.name":{},"f:project":{}}}},"manager":"Go-http-client","operation":"Update","time":1666691675000}],"name":"biao-pu-cloud-2022","resourceVersion":"10633661","uid":"b22d1fd7-d03c-4b70-89b3-fa2620e00251"},"spec":{"finalizers":["kubernetes"]},"status":{"phase":"Active"}}'
}
const findTaskList = {
  current: 1,
  pages: 10,
  size: 10,
  total: 50,
  'records|50': [
    {
      cpu: 4,
      createDate: '@date("yyyy-MM-dd")',
      deployEnvir: 0,
      failureReason: '123213123213123213123213123213123213123213123213123213123213123213123213123213123213123213',
      imageName: '21',
      imagePath: '21',
      nameSpace: '21',
      ram: '1024Mi',
      replicas: 6,
      taskDesc: '123213',
      taskId: '@id',
      taskName: '@name',
      'taskStatus|1': [0, 1, 2, 4],
      taskTag: '3',
      updateDate: '@date("yyyy-MM-dd")'
    }
  ]
}

const packageList = {
  'list|3': [
    {
      appName: '@name',
      packageName: '@name',
      createDate: '@date("yyyy-MM-dd")'
    }
  ]
}
const systemNameList = [
  {
    systemName: 'Saas管理平台',
    systemList: [
      { packageName: 'biaopu-saas-gateway', appName: 'SAAS网关服务', createDate: '2022-11-10 10:57:15' },
      { packageName: 'biaopu-tenant-admin', appName: 'SAAS租户中心', createDate: '2022-11-10 10:58:31' },
      { packageName: 'biaopu-saas-web', appName: 'SAAS管理平台(前端)', createDate: '2022-11-17 10:22:03' },
      { packageName: 'biaopu-deploy-admin', appName: 'SAAS部署/升级', createDate: '2022-11-29 10:15:02' }
    ]
  },
  {
    systemName: '票税全电应用',
    systemList: [
      { packageName: 'eims-web', appName: '全电(前端)', createDate: '2022-12-09 15:49:10' },
      { packageName: 'eims-service', appName: '全电(后端)', createDate: '2022-12-12 16:08:51' }
    ]
  }
]
const deploymentList = {
  'list|3': [
    {
      creationTimestamp: '@date("yyyy-MM-dd")',
      image: '21',
      name: '@name',
      namespace: '@name',
      port: 80,
      replicas: 5,
      status: 'True'
    }
  ]
}
const podList = {
  'list|3': [
    {
      cpu: 4,
      creationTimestamp: '@date("yyyy-MM-dd")',
      hostIp: '12:13:13:21',
      memory: 5,
      name: '@name',
      namespace: '@name',
      podIp: '12',
      restartCount: 5,
      status: 'True'
    }
  ]
}
const findAppList = {
  current: 1,
  pages: 10,
  size: 10,
  total: 50,
  'records|50': [
    {
      appDescribe: '',
      appId: '@id',
      appName: '@name',
      'appPlatform|1': [0, 1],
      'appStatus|1': [0, 1],
      createDate: '@date("yyyy-MM-dd")',
      id: '@id',
      requestUrl: '@url',
      updateDate: '@date("yyyy-MM-dd")'
    }
  ]
}
const findProjectList = {
  current: 1,
  pages: 10,
  size: 10,
  total: 50,
  'records|50': [
    {
      appName: '@name',
      cpu: 4,
      createDate: '@date("yyyy-MM-dd")',
      id: '@id',
      memory: '4',
      packageName: '@name',
      port: 80,
      systemName: '@name',
      updateDate: '@date("yyyy-MM-dd")'
    }
  ]
}
export default {
  listReposDetails,
  listNamespaces,
  listNamespaced,
  namespacedYaml,
  deploymentList,
  findTaskList,
  podList,
  packageList,
  systemNameList,
  listRepositoryTags,
  findAppList,
  findProjectList
}
